Skip to content

[SPARK-55392][PYTHON][INFRA] Upgrade Python 3.14 test image to Ubuntu 24.04#54175

Closed
zhengruifeng wants to merge 5 commits intoapache:masterfrom
zhengruifeng:ubuntu_24_py_14
Closed

[SPARK-55392][PYTHON][INFRA] Upgrade Python 3.14 test image to Ubuntu 24.04#54175
zhengruifeng wants to merge 5 commits intoapache:masterfrom
zhengruifeng:ubuntu_24_py_14

Conversation

@zhengruifeng
Copy link
Copy Markdown
Contributor

@zhengruifeng zhengruifeng commented Feb 6, 2026

What changes were proposed in this pull request?

Upgrade Python 3.14 test image to Ubuntu 24.04

Why are the changes needed?

to test with a newer OS version

Does this PR introduce any user-facing change?

no, infra-only

How was this patch tested?

PR builder with

default: '{"PYSPARK_IMAGE_TO_TEST": "python-314", "PYTHON_TO_TEST": "python3.14"}'

https://github.com/zhengruifeng/spark/actions/runs/21749581852/job/62744447326

Was this patch authored or co-authored using generative AI tooling?

No

@github-actions
Copy link
Copy Markdown

github-actions bot commented Feb 6, 2026

JIRA Issue Information

=== Improvement SPARK-55392 ===
Summary: Upgrade Python 3.14 test image to Ubuntu 24.04
Assignee: None
Status: Open
Affected: ["4.2.0"]


This comment was automatically generated by GitHub Actions

@zhengruifeng zhengruifeng marked this pull request as ready for review February 6, 2026 13:10
# Setup virtual environment
ENV VIRTUAL_ENV=/opt/spark-venv
RUN python3.14 -m venv --without-pip $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a bit weird, why don't we activate virtual env normally? I think it does more than changing PATH. Why do we need the venv in the first place?

Copy link
Copy Markdown
Contributor Author

@zhengruifeng zhengruifeng Feb 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a AI-recommended approach, and the source is https://pythonspeed.com/articles/activate-virtualenv-dockerfile/

FROM python:3.12-slim
RUN python3 -m venv /opt/venv

# This is wrong!
RUN . /opt/venv/bin/activate

# Install dependencies:
COPY requirements.txt .
RUN pip install -r requirements.txt

# Run the application:
COPY myapp.py .
CMD ["python", "myapp.py"]

it said the the normal way to activate venv only take effect in its RUN command, I didn't try it though

@zhengruifeng zhengruifeng deleted the ubuntu_24_py_14 branch February 7, 2026 08:22
@zhengruifeng
Copy link
Copy Markdown
Contributor Author

merged to master

Yicong-Huang pushed a commit to Yicong-Huang/spark that referenced this pull request Feb 8, 2026
… 24.04

### What changes were proposed in this pull request?
Upgrade Python 3.14 test image to Ubuntu 24.04

### Why are the changes needed?
to test with a newer OS version

### Does this PR introduce _any_ user-facing change?
no, infra-only

### How was this patch tested?
PR builder with
```
default: '{"PYSPARK_IMAGE_TO_TEST": "python-314", "PYTHON_TO_TEST": "python3.14"}'
```

https://github.com/zhengruifeng/spark/actions/runs/21749581852/job/62744447326

### Was this patch authored or co-authored using generative AI tooling?
No

Closes apache#54175 from zhengruifeng/ubuntu_24_py_14.

Authored-by: Ruifeng Zheng <[email protected]>
Signed-off-by: Ruifeng Zheng <[email protected]>
rpnkv pushed a commit to rpnkv/spark that referenced this pull request Feb 18, 2026
… 24.04

### What changes were proposed in this pull request?
Upgrade Python 3.14 test image to Ubuntu 24.04

### Why are the changes needed?
to test with a newer OS version

### Does this PR introduce _any_ user-facing change?
no, infra-only

### How was this patch tested?
PR builder with
```
default: '{"PYSPARK_IMAGE_TO_TEST": "python-314", "PYTHON_TO_TEST": "python3.14"}'
```

https://github.com/zhengruifeng/spark/actions/runs/21749581852/job/62744447326

### Was this patch authored or co-authored using generative AI tooling?
No

Closes apache#54175 from zhengruifeng/ubuntu_24_py_14.

Authored-by: Ruifeng Zheng <[email protected]>
Signed-off-by: Ruifeng Zheng <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants